package com.emergency.embackend.mapper;

import com.emergency.embackend.entity.Share;
import com.emergency.embackend.entity.ShareComment;
import com.emergency.embackend.vo.ShareDetailVO;
import com.emergency.embackend.vo.ShareVO;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface ShareDataMapper {
    void add(Share share, Long userId);

    void delete(Long id);

    void update(Share share);

    List<ShareDetailVO> page(Long userId);

    List<Share> pageAll();

    List<ShareDetailVO> pageTime();

    ShareDetailVO getOne(Long Id);

    List<Share> underView();

    void changeStatus(char status, Long id);

    void addStatusLog(char status, Long id);



    List<ShareComment> getComment(Long shareId);

    ShareDetailVO getUserOne(Long id);

    Long getDataInWeek(Long id);

    Long getDataInMonth(Long id);

    List<ShareDetailVO> pageComment(Long userId);

    void addComment(Long userId, ShareComment shareComment);


    Long getViewCount(Long shareId);

    List<ShareVO> getHistory(Long userId);
}
